﻿using System;
using System.Collections.Generic;
using System.Xml.Serialization;
using Data.RelativeObjects;

namespace Data.Realm
{
    [Serializable]
    [XmlType("g")]
    public class OrientedField : Field
    {
        [XmlAttribute]
        public int x, y;
        [XmlElement("a")]
        public Tractor tractor;

        public OrientedField(Field field, int i, int j,  Tractor tractor = null)
        {
            this.tractor = tractor;
            this.x = i;
            this.y = j;
        }

        public OrientedField(Field field, KeyValuePair<int, int> pos, Tractor tractor = null)
        {
            this.tractor = tractor;
            this.x = pos.Key;
            this.y = pos.Value;
        }

        public OrientedField()
        {
        }
    }

}

